package o;

import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import androidx.annotation.NonNull;
import androidx.recyclerview.widget.RecyclerView.a;
import androidx.recyclerview.widget.RecyclerView.s;
import com.huawei.appgallery.foundation.ui.framework.cardkit.bean.CardBean;
import com.huawei.appmarket.service.store.awk.bean.VideoStreamListCardBean;
import com.huawei.appmarket.service.videostream.view.VideoStreamItemCard;
import java.util.ArrayList;
import java.util.List;
import o.ewm.h;

public class emr extends a<s> {
    private List<VideoStreamListCardBean> ˋ = new ArrayList();

    class d extends s {
        VideoStreamItemCard ʻॱ;
        final /* synthetic */ emr ᐝॱ;

        public d(emr o_emr, View view) {
            this.ᐝॱ = o_emr;
            super(view);
            this.ʻॱ = new VideoStreamItemCard(view.getContext());
            this.ʻॱ.ˋ(view);
        }
    }

    public emr(List<VideoStreamListCardBean> list) {
        ˊ(list);
    }

    public void ˋ(List<VideoStreamListCardBean> list) {
        ˊ(list);
    }

    private void ˊ(List<VideoStreamListCardBean> list) {
        if (!CollectCheck.isEmpty(list)) {
            this.ˋ.clear();
            this.ˋ.addAll(list);
            ˊ();
        }
    }

    @NonNull
    public s ˎ(@NonNull ViewGroup viewGroup, int i) {
        return new d(this, LayoutInflater.from(viewGroup.getContext()).inflate(h.ꓸॱ, viewGroup, false));
    }

    public void ॱ(@NonNull s sVar, int i) {
        ((d) sVar).ʻॱ.ˏ((CardBean) this.ˋ.get(i));
    }

    public int ˏ() {
        return this.ˋ.size();
    }

    public long ˏ(int i) {
        return (long) i;
    }
}
